package com.zhfi.dataapply.schedule.reader.chaincode;

import com.zhfi.dataapply.entity.data.po.chaincode.IndustryBaseInfoPO;
import com.zhfi.dataapply.service.CVSourceUrlService;
import com.zhfi.dataapply.service.ForwardService;
import com.zhfi.dataapply.service.chaincode.OriginChainCodeListService;
import lombok.Getter;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
public class IndustryBaseInfoReader extends AbstractChainKeyReader<IndustryBaseInfoPO> {


    private static String URL_ID = "12.2";

    @Autowired
    private CVSourceUrlService cvSourceUrlService;

    @Getter
    private String url;

    @Autowired
    public IndustryBaseInfoReader(ForwardService forwardService, OriginChainCodeListService originChainCodeListService) {
        super(IndustryBaseInfoPO.class, forwardService, originChainCodeListService);
    }

    @Override
    public void resetUrl() {
        this.url = cvSourceUrlService.getUrlById(URL_ID);
    }
}
